//package com.example.villagedevelop.generator.config;
//
//import lombok.Value;
//import lombok.extern.slf4j.Slf4j;
//import org.springframework.boot.ApplicationRunner;
//import org.springframework.context.annotation.Bean;
//import org.springframework.context.annotation.Configuration;
//import org.springframework.stereotype.Controller;
//
//import java.net.InetAddress;
//import java.net.UnknownHostException;
//
//@Slf4j
//@Controller
//@Configuration
//public class LogConfig {
//
//    @Value("${user.home}")
//    private String userName;
//
//    /**
//     * 端口
//     */
//    @Value("${server.port}")
//    private String port;/**
//     * 启动成功
//     */
//    @Bean
//    public ApplicationRunner applicationRunner() {
//        return applicationArguments -> {
//            try {
//                InetAddress ia = InetAddress.getLocalHost();
//                //获取本机内网IP
//                log.info("启动成功：" + "http://" + ia.getHostAddress() + ":" + port + "/");
//                log.info("${user.home} ：" + userName);
//            } catch (UnknownHostException ex) {
//                ex.printStackTrace();
//            }
//        };
//    }
//}
